/*
============================================================================
 Name        : BlockSetGridCol.h
 Author      : \x{738b}\x{658c}
 Version     :
 Copyright   : \x{76ca}\x{76df}\x{8f6f}\x{4ef6}
 Description : CBlockSetGridCol declaration
============================================================================
*/

#ifndef BLOCKSETGRIDCOL_H
#define BLOCKSETGRIDCOL_H

// INCLUDES
#include <e32std.h>
#include <e32base.h>
#include "Block.h"

// CLASS DECLARATION

/**
*  CBlockSetGridCol
* 
*/
class CBlockSetGridCol : public CBlock
{
public:
	~CBlockSetGridCol();

	static CBlockSetGridCol* NewL(CBaseBlock* bsBack,const RArray<TInt>& psIdArr,const CDesCArray* pstrArr);

	static CBlockSetGridCol* NewLC(CBaseBlock* bsBack,const RArray<TInt>& psIdArr,const CDesCArray* pstrArr);

private:
	CBlockSetGridCol(CBaseBlock* bsBack);

	void ConstructL(const RArray<TInt>& psIdArr,const CDesCArray* pstrArr);

protected:
	void BeforeDraw(CFbsBitGc& g) const;

private:
	void OnDraw(CFbsBitGc& g)const;

	void OnKeyDown(TInt keyCode);
	
	void InitPopMenu(const TInt& nType);

	TBool OnMenuEvent(TInt menuId);

	void OnMouseUp(const TPoint& aPt);
	
	void SizeChanged();

private:
	RArray<TInt> m_psID;
	CDesCArray* m_pstrName;

	TBuf<10>	m_strColNum;
	TBuf<10>	m_strIndName;
	TBuf<10>	m_strFmt;
	TInt		m_nCurrent;
};

#endif // BLOCKSETGRIDCOL_H
